<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>glGetTexParameter - OpenGL ES 3.1 Reference Pages</title>
    <link rel="stylesheet" type="text/css" href="opengl-man.css"/>
    <meta name="generator" content="DocBook XSL Stylesheets V1.78.1"/>
    <script type="text/x-mathjax-config">
            MathJax.Hub.Config({
                MathML: {
                    extensions: ["content-mathml.js"]
                },
                tex2jax: {
                    inlineMath: [['$','$'], ['\\(','\\)']]
                }
            });
        </script>
    <script type="text/javascript" src="https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML"/>
  </head>
  <body>
    <header/>
    <div class="refentry" id="glGetTexParameter">
      <div class="titlepage"/>
      <div class="refnamediv">
        <h2>Name</h2>
        <p>glGetTexParameter — return texture parameter values</p>
      </div>
      <div class="refsynopsisdiv">
        <h2>C Specification</h2>
        <div class="funcsynopsis">
          <table style="border: 0; cellspacing: 0; cellpadding: 0;" class="funcprototype-table">
            <tr>
              <td>
                <code class="funcdef">void <strong class="fsfunc">glGetTexParameterfv</strong>(</code>
              </td>
              <td>GLenum <var class="pdparam">target</var>, </td>
            </tr>
            <tr>
              <td> </td>
              <td>GLenum <var class="pdparam">pname</var>, </td>
            </tr>
            <tr>
              <td> </td>
              <td>GLfloat * <var class="pdparam">params</var><code>)</code>;</td>
            </tr>
          </table>
          <div class="funcprototype-spacer"> </div>
        </div>
        <div class="funcsynopsis">
          <table style="border: 0; cellspacing: 0; cellpadding: 0;" class="funcprototype-table">
            <tr>
              <td>
                <code class="funcdef">void <strong class="fsfunc">glGetTexParameteriv</strong>(</code>
              </td>
              <td>GLenum <var class="pdparam">target</var>, </td>
            </tr>
            <tr>
              <td> </td>
              <td>GLenum <var class="pdparam">pname</var>, </td>
            </tr>
            <tr>
              <td> </td>
              <td>GLint * <var class="pdparam">params</var><code>)</code>;</td>
            </tr>
          </table>
          <div class="funcprototype-spacer"> </div>
        </div>
      </div>
      <div class="refsect1" id="parameters">
        <h2>Parameters</h2>
        <div class="variablelist">
          <dl class="variablelist">
            <dt>
              <span class="term">
                <em class="parameter">
                  <code>target</code>
                </em>
              </span>
            </dt>
            <dd>
              <p>
                    Specifies the symbolic name of the target texture.
                    <code class="constant">GL_TEXTURE_2D</code>,
                    <code class="constant">GL_TEXTURE_2D_ARRAY</code>,
                    <code class="constant">GL_TEXTURE_2D_MULTISAMPLE</code>,
                    <code class="constant">GL_TEXTURE_3D</code>, and
                    <code class="constant">GL_TEXTURE_CUBE_MAP</code>
                    are accepted.
                </p>
            </dd>
            <dt>
              <span class="term">
                <em class="parameter">
                  <code>pname</code>
                </em>
              </span>
            </dt>
            <dd>
              <p>
                    Specifies the symbolic name of a texture parameter.
                    <code class="constant">GL_DEPTH_STENCIL_TEXTURE_MODE</code>,
					<code class="constant">GL_IMAGE_FORMAT_COMPATIBILITY_TYPE</code>,
                    <code class="constant">GL_TEXTURE_BASE_LEVEL</code>,
                    <code class="constant">GL_TEXTURE_COMPARE_FUNC</code>,
                    <code class="constant">GL_TEXTURE_COMPARE_MODE</code>,
                    <code class="constant">GL_TEXTURE_IMMUTABLE_FORMAT</code>,
                    <code class="constant">GL_TEXTURE_IMMUTABLE_LEVELS</code>,
                    <code class="constant">GL_TEXTURE_MAG_FILTER</code>,
                    <code class="constant">GL_TEXTURE_MAX_LEVEL</code>,
                    <code class="constant">GL_TEXTURE_MAX_LOD</code>,
                    <code class="constant">GL_TEXTURE_MIN_FILTER</code>,
                    <code class="constant">GL_TEXTURE_MIN_LOD</code>,
                    <code class="constant">GL_TEXTURE_SWIZZLE_R</code>,
                    <code class="constant">GL_TEXTURE_SWIZZLE_G</code>,
                    <code class="constant">GL_TEXTURE_SWIZZLE_B</code>,
                    <code class="constant">GL_TEXTURE_SWIZZLE_A</code>,
                    <code class="constant">GL_TEXTURE_WRAP_S</code>,
                    <code class="constant">GL_TEXTURE_WRAP_T</code>, and
                    <code class="constant">GL_TEXTURE_WRAP_R</code>
                    are accepted.
                </p>
            </dd>
            <dt>
              <span class="term">
                <em class="parameter">
                  <code>params</code>
                </em>
              </span>
            </dt>
            <dd>
              <p>
                    Returns the texture parameters.
                </p>
            </dd>
          </dl>
        </div>
      </div>
      <div class="refsect1" id="description">
        <h2>Description</h2>
        <p>
            <code class="function">glGetTexParameter</code> returns in <em class="parameter"><code>params</code></em> the value or values of the texture parameter
            specified as <em class="parameter"><code>pname</code></em>.
            <em class="parameter"><code>target</code></em> defines the target texture.
            <code class="constant">GL_TEXTURE_2D</code>,
            <code class="constant">GL_TEXTURE_3D</code>,
            <code class="constant">GL_TEXTURE_2D_MULTISAMPLE</code>,
            <code class="constant">GL_TEXTURE_2D_ARRAY</code>, and
            <code class="constant">GL_TEXTURE_CUBE_MAP</code>
            specify two- or three-dimensional, two-dimensional array, two-dimensional multisample, or cube-mapped texturing, respectively.
            <em class="parameter"><code>pname</code></em> accepts the same symbols as <a class="citerefentry" href="glTexParameter.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexParameter</span></span></a>,
            with the same interpretations:
        </p>
        <div class="variablelist">
          <dl class="variablelist">
            <dt>
              <span class="term">
                <code class="constant">GL_DEPTH_STENCIL_TEXTURE_MODE</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-value depth stencil texture mode, a symbolic constant.
                        The initial value is <code class="constant">GL_DEPTH_COMPONENT</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_IMAGE_FORMAT_COMPATIBILITY_TYPE</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued image format compatibility matching criteria. This can be one of 
						<code class="constant">GL_IMAGE_FORMAT_COMPATIBILITY_BY_CLASS</code> or 
						<code class="constant">GL_IMAGE_FORMAT_COMPATIBILITY_BY_SIZE</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_BASE_LEVEL</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued base texture mipmap level.  The initial value is 0.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_COMPARE_FUNC</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns a single-valued texture comparison function, a symbolic constant.  The
                        initial value is <code class="constant">GL_LEQUAL</code>. See <a class="citerefentry" href="glTexParameter.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexParameter</span></span></a>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_COMPARE_MODE</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns a single-valued texture comparison mode, a symbolic constant.  The
                        initial value is <code class="constant">GL_NONE</code>. See <a class="citerefentry" href="glTexParameter.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexParameter</span></span></a>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_IMMUTABLE_FORMAT</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns a single-value boolean representing the immutability of the texture format and size.
                        initial value is <code class="constant">GL_FALSE</code>. See <a class="citerefentry" href="glTexStorage2D.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexStorage2D</span></span></a>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_IMMUTABLE_LEVELS</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns a single-valued number of texture levels in an immutable texture.
                        See <a class="citerefentry" href="glTexStorage2D.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexStorage2D</span></span></a>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_MAG_FILTER</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued texture magnification filter,
                        a symbolic constant. The initial value is <code class="constant">GL_LINEAR</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_MAX_LEVEL</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued maximum texture mipmap array level.  The initial
                        value is 1000.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_MAX_LOD</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued texture maximum level-of-detail value. The
                        initial value is 1000.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_MIN_FILTER</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued texture minification filter,
                        a symbolic constant. The initial value is <code class="constant">GL_NEAREST_MIPMAP_LINEAR</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_MIN_LOD</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued texture minimum level-of-detail value.  The
                        initial value is
                        <math overflow="scroll">
                            
                            <mn>-1000</mn>
                        </math>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_SWIZZLE_R</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the red component swizzle. The initial value is <code class="constant">GL_RED</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_SWIZZLE_G</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the green component swizzle. The initial value is <code class="constant">GL_GREEN</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_SWIZZLE_B</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the blue component swizzle. The initial value is <code class="constant">GL_BLUE</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_SWIZZLE_A</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the alpha component swizzle. The initial value is <code class="constant">GL_ALPHA</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_WRAP_S</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued wrapping function for texture coordinate
                        <math overflow="scroll"><mi mathvariant="italic">s</mi></math>,
                        a symbolic constant. The initial value is <code class="constant">GL_REPEAT</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_WRAP_T</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued wrapping function for texture coordinate
                        <math overflow="scroll"><mi mathvariant="italic">t</mi></math>,
                        a symbolic constant. The initial value is <code class="constant">GL_REPEAT</code>.
                    </p>
            </dd>
            <dt>
              <span class="term">
                <code class="constant">GL_TEXTURE_WRAP_R</code>
              </span>
            </dt>
            <dd>
              <p>
                        Returns the single-valued wrapping function for texture coordinate
                        <math overflow="scroll"><mi mathvariant="italic">r</mi></math>,
                        a symbolic constant. The initial value is <code class="constant">GL_REPEAT</code>.
                    </p>
            </dd>
          </dl>
        </div>
      </div>
      <div class="refsect1" id="notes">
        <h2>Notes</h2>
        <p>
            If an error is generated,
            no change is made to the contents of <em class="parameter"><code>params</code></em>.
        </p>
      </div>
      <div class="refsect1" id="errors">
        <h2>Errors</h2>
        <p>
            <code class="constant">GL_INVALID_ENUM</code> is generated if <em class="parameter"><code>target</code></em> or <em class="parameter"><code>pname</code></em> is not an
            accepted value.
        </p>
      </div>
      <div class="refsect1" id="versions">
        <h2>API Version Support</h2>
        <div class="informaltable">
          <table style="border-collapse: collapse; border-top: 2px solid ; border-bottom: 2px solid ; border-left: 2px solid ; border-right: 2px solid ; ">
            <colgroup>
              <col style="text-align: left; "/>
              <col style="text-align: center; " class="firstvers"/>
              <col style="text-align: center; "/>
              <col style="text-align: center; " class="lastvers"/>
            </colgroup>
            <thead>
              <tr>
                <th style="text-align: left; border-right: 2px solid ; ">
                 
            </th>
                <th style="text-align: center; border-bottom: 2px solid ; " colspan="3">
                <span class="bold"><strong>OpenGL ES API Version</strong></span>
            </th>
              </tr>
              <tr>
                <th style="text-align: left; border-right: 2px solid ; border-bottom: 2px solid ; ">
                <span class="bold"><strong>Function Name</strong></span>
            </th>
                <th style="text-align: center; border-right: 2px solid ; border-bottom: 2px solid ; ">
                <span class="bold"><strong>2.0</strong></span>
            </th>
                <th style="text-align: center; border-right: 2px solid ; border-bottom: 2px solid ; ">
                <span class="bold"><strong>3.0</strong></span>
            </th>
                <th style="text-align: center; border-bottom: 2px solid ; ">
                <span class="bold"><strong>3.1</strong></span>
            </th>
              </tr>
            </thead>
            <tbody>
              <tr>
                <td style="text-align: left; border-right: 2px solid ; border-bottom: 2px solid ; ">
                  <code class="function">glGetTexParameterfv</code>
                </td>
                <td style="text-align: center; border-right: 2px solid ; border-bottom: 2px solid ; ">✔</td>
                <td style="text-align: center; border-right: 2px solid ; border-bottom: 2px solid ; ">✔</td>
                <td style="text-align: center; border-bottom: 2px solid ; ">✔</td>
              </tr>
              <tr>
                <td style="text-align: left; border-right: 2px solid ; ">
                  <code class="function">glGetTexParameteriv</code>
                </td>
                <td style="text-align: center; border-right: 2px solid ; ">✔</td>
                <td style="text-align: center; border-right: 2px solid ; ">✔</td>
                <td style="text-align: center; ">✔</td>
              </tr>
            </tbody>
          </table>
        </div>
      </div>
      <div class="refsect1" id="seealso">
        <h2>See Also</h2>
        <p>
            <a class="citerefentry" href="glTexParameter.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexParameter</span></span></a>,
                        <a class="citerefentry" href="glTexStorage2D.xhtml"><span class="citerefentry"><span class="refentrytitle">glTexStorage2D</span></span></a>
        </p>
      </div>
      <div class="refsect1" id="Copyright">
        <h2>Copyright</h2>
        <p>
            Copyright <span class="trademark"/>© 1991-2006 Silicon Graphics, Inc.
            Copyright <span class="trademark"/>© 2010-2014 Khronos Group.
            This document is licensed under the SGI Free Software B License.
            For details, see
            <a class="link" href="http://oss.sgi.com/projects/FreeB/" target="_top">http://oss.sgi.com/projects/FreeB/</a>.
        </p>
      </div>
    </div>
    <footer/>
  </body>
</html>
